using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using Inventory.ObjectInterfaces;

namespace Inventory.Domain.Models
{
    public class Movie : IObjectWithState
    {
        public Movie()
        {
            this.MovieCharacters = new List<MovieCharacter>();
            this.MoviesMovieGenres = new List<MoviesMovieGenre>();
            this.MoviesPersonsProfessions = new List<MoviesPersonsProfession>();
        }

        public int Id { get; set; }
        [Display(Name = "IMDB Id") ]
        public int? IMDbId { get; set; }
        [Display(Name = "Rotten Tomatoes Id")]
        public int? RtId { get; set; }
        [MaxLength(200) ]
        public string Title { get; set; }
        public int? MovieRatingId { get; set; }
        
        public int? Runtime { get; set; }
        public string SynopsisLong { get; set; }
        public string SynopsisShort { get; set; }
        public string PlotOutline { get; set; }
        public string Comments { get; set; }
        public string InternetUrl { get; set; }
        public decimal? UserRating { get; set; }
        public decimal? MyRating { get; set; }
        public int? ReleaseYear { get; set; }
        public string Poster { get; set; }
        public string PosterThumb { get; set; }
        public virtual ICollection<MovieCharacter> MovieCharacters { get; set; }
        public virtual MovieRating MovieRating { get; set; }
        public virtual ICollection<MoviesMovieGenre> MoviesMovieGenres { get; set; }
        public virtual ICollection<MoviesPersonsProfession> MoviesPersonsProfessions { get; set; }
        [NotMapped]
        public State State { get; set; }
    }
}
